Simple Activation Licensing

This tutorial demonstrates a simple activation licensing scenario in which you can easily deploy the Activation Server and manage licensing of your application. While LicenseKey Manager is a licensing tool for your desktop/laptop computer, you can use the Activation Server as the online web-based tool that you can manage licensing from anywhere and from different devices. 

 

In this tutorial, we assume that your application is protected as a trial (general evaluation) node-locked license. Specifically, you want to distribute your application as a trial version in which the user can try out the application immediately after installation. To continue to use the application after the trial period, the user must register (or pay a license fee) for the Activation Key to activate and turn the trial version into the full registered version.

 

Based on the settings used in this tutorial, the following describes how the user would experience the protected application.

 

·         When starting the application, the Registration and Activation dialog box pops up. The user may click the Register Later button to skip registration during the trial period.

·         The user can try out the application for a limited trial period.

·         The user cannot gain additional trial period by reinstalling the application or turning back the system clock.

·         From the Registration and Activation dialog box, the user can register at any time by clicking the Register button, which will link to your registration web page.

·         When you receive an order from the user, you can log in to your Activation Server to issue an Activation Key and send an order confirmation email to the user.

·         The user can activate the application instantly online by entering the Activation Key in the Registration and Activation dialog box.

·         Alternatively, if the user’s computer does not have an Internet connection, the user may use the offline activation method.

·         The user may contact you by email, phone, or through your activation web page, and provide the Activation Key and Registration ID (shown in the Registration and Activation dialog box).

·         With the received Activation Key and Registration ID, you can log in to your Activation Server and manually generate the License Key to be returned to the user.

·         The user can activate the application offline by entering the License Key in the Registration and Activation dialog box.

Protecting Applications

The following instructions use ElecKey Integrator (the shell protection method) to protect the application. The necessary settings are described below. However, you may change the options as you want.

 

Besides the shell protection method, you may also use the provided KeyCheck API (including the KeyCheck Class Library and the KeyCheck .NET Component) to protect your application, by specifying the same settings as described below. Please see Protecting Applications Using API and the provided code examples for more information.

To Protect an Application

1.       Run ElecKey Integrator. The wizard dialog box appears.

2.       In the Select Application License Type dialog, select Machine License.

3.       In the Select Integration Task dialog, select Protect Code and Enforce Licensing.

4.       In the Specify Protected Program dialog, specify your executable file name in the Original field. In the Target field, specify a different name for the protected executable file that will be created.

5.       In the Set Identification dialog, assign a Program ID in the Program ID field.

6.       In the Key Detection Method dialog, select Detect Stand-Alone Key.

7.       In the Set Options dialog, you can use the default settings.

8.       In the Choose Implementation dialog, select Evaluation.

9.       In the Select Evaluation Mode dialog, select General Evaluation and specify the limits as you want.

10.    In the Customize Messages dialog, the needed dialog boxes for the implementation you have chosen are automatically checked. However, you can enable the dialog boxes as well as edit messages and options as you want.

11.    From the Dialog Box Style drop-down list, select Default Dialog Box/Auto-Activation. Then, click the Edit button of the Registration Dialog Box checkbox.

12.    In the Registration Dialog Box Properties dialog box, under the Appearance Options box, select Show auto activation first, followed by manual activation from the drop-down list.

13.    Click the Options tab. Then, in the URL/Email/Document/Executable field, enter your registration web page URL. For instance, https://demo.eleckey.net/registration_activation.aspx.

14.    In the Web Service URL field, enter your Activation Server web service URL. For instance, https://demo.eleckey.net/service.asmx.

15.    In the Create End-User Utilities dialog, the needed end-user utilities for the implementation you have chosen are automatically checked. However, you can choose to build the end-user utilities as you want.

16.    In the Summary dialog, review the action you have chosen.

17.    Click the Integrate button. The protected version of your executable file is created.

 

It is recommended that you save your unprotected executable file in a safe place. You can then rename the protected version to its original file name, and use it further to create a setup package and distribute your application to the user.

Distributing Protected Applications

To create a setup package and distribute your application, please ensure to include the protected version of your executable file and the ElecKey system files. For Win32/Win64/.NET applications, the following is the list of the needed system files:

 

·         Ekc3220.dll (in \Deploy\Win32App\KeyCheck\)

·         Ekc6420.dll (in \Deploy\Win64App\KeyCheck\)

·         Ekag20nt.exe (in \Deploy\Win32App\KeyCheck\)

·         Ekag6420.exe (in \Deploy\Win64App\KeyCheck\)

·         End-user utilities (optional)

The above system files must be placed in the same directory as the protected executable file. Depending on the features you have enabled, you may need additional system files. See the topic Protecting Windows Apps/Deployment for more details.

Setting up Activation Server

Before you can use the Activation Server to license your application, you must first create a product in the Products table. This table contains information about the product and the Master ID and Master License, which encode the licensing properties of the product. You can generate the Master ID and Master License by using the LicenseKey Manager tool.

To Generate Master ID and Master License

1.       Run LicenseKey Manager.

2.       From the Tools menu, select Generate Master ID.

3.       In the Generate Master ID dialog box, from the Program ID drop-down list, select the Program ID of your application. Then, click the Generate button. A Master ID is generated.

4.       Copy the Master ID. Then, go to the Main tab of the Key Properties pane. Paste the Master ID in the Registration ID field, and click the Check button.

5.       The Identification field shows the Key ID, Program ID, and flag decoded from the Master ID.

6.       From the Implementation drop-down list:

·         Select Distribution if you want to generate the Master License that turns the application into the full version with no limit.

7.       From the Note pane, you can enter notes about the Master ID and Master License in the Messages field.

8.       From the Main tab of the Key Properties pane, click the Generate button. The Master License is shown in the License Key field.

To Add a Product

1.       Log in to Activation Manager, and click the Products menu.

2.       Click the Insert New Product button. A new record is created.

3.        On the new record, click the Edit button.

4.       In the ProductName edit box, enter your product name.

5.       In the ProgramID edit box, enter the Program ID of your application.

6.       In the MasterID and MasterLicense edit boxes, enter the Master ID and Master License generated by LicenseKey Manager.

7.       In the MaxActivation edit box, enter the maximum number of activations allowed, or enter -1 for unlimited activations.

8.       In the ProductTitle edit box, enter the full title of your product.

9.       Click the Update button. 

Licensing Protected Applications

You can license the protected application by creating an activation account in the Activation Server, and then associating it with a product listed in the Products table. Each activation account contains a unique Activation Key that is randomly generated. To issue the license, you can easily send an order confirmation email containing the Activation Key right from Activation Manager. You can customize the email through the following template files:

 

\ACTIVATIONSERVER\PRECOMPILEDWEB\MANAGER\EMAILSUBJECT.TXT

 

\ACTIVATIONSERVER\PRECOMPILEDWEB\MANAGER\EMAILBODY.TXT

To Add an Account

1.       Log in to Activation Manager, and click the Accounts menu.

2.       Below the menu bar, under New Account, select a product from the drop-down list. Then, click the Insert New Account button. A new record is created.

3.       On the new record, click the Edit button.

4.       You can enter the user information in the provided fields such as PurchaseID, PurchaseDate, FirstName, LastName, Company, Email, etc.

5.       Click the Update button.

Providing Web-Based and Offline Activation

Besides automatic online activation, you can optionally provide offline activation in case if the user’s computer does not have an Internet connection. Offline activation requires that the user must provide the Activation Key and Registration ID (shown in the Registration and Activation dialog box). You can then generate the License Key to be returned to the user.

 

The Activation Server already includes the ready-to-use activation web page. To provide web-based activation, you can customize from the following file:

 

\ACTIVATIONSERVER\PRECOMPILEDWEB\MANAGER\REGISTRATION_ACTIVATION.ASPX

 

note NOTE: If you use the trial version of ElecKey, you can access the live demo of the activation web page, which is available online at:

https://demo.eleckey.net/registration_activation.aspx

 

To provide offline activation by phone, email, etc., you can log in to your Activation Server and manually generate the License Key to be returned to the user.

To Generate a License Key

1.       Log in to Activation Manager, and click the Control menu.

2.       Below the menu bar, enter the Activation Key and click the Get Information button.

3.       Under the License Activation box, enter the Registration ID and click the Activate button.

4.       The License Key is generated and shown in the Activation Logs pane.